1. Field of the Invention
The present invention generally relates to redundant data encoding schemes and data communication modulation schemes, and more particularly to a method and apparatus for communicating data between an implantable medical device and an external medical device that improves detectability of communication errors.
2. Background Information
There are many applications in which it is important to provide data communication that is substantially error-free. One such application is the programming of an implantable medical device such as a cardiac stimulator, which might be a pacemaker or a defibrillator, for example. Such devices are often programmed via an external medical device, known generally as a programmer, that includes a wand that can be located in proximity to the cardiac stimulator to establish a non-contacting communication link with the cardiac stimulator. The communication link can involve a transmitted electromagnetic signal that is modulated in accordance with the data to be communicated. The communication link requires an extremely high degree of reliability since any information going into the cardiac stimulator has the potential to immediately alter the therapeutic performance of that device.
When communicating information to or from an implantable medical device, it is a common practice to encode the information in a way that will increase the probability that errors in transmission will be detected. The encoding involves adding redundant information to the original message information to create coded information. In implantable medical devices, the most common type of encoding is a block code, where discrete packets of message information are encoded and the coded information is transmitted in discrete blocks.
When using a block code, the usual method for increasing the probability that errors will be detected is to increase the amount of redundant information. The disadvantages of this are a proportional increase in communication time and an increase in encoder/decoder hardware complexity to accommodate the larger block code size.
One known communication modulation technique is pulse-position-modulation (PPM). In PPM, pulses are transmitted and information is encoded as the time between a synchronization pulse and an information pulse. A derivative of PPM is relative-pulse-position-modulation (RPPM). In RPPM, information is encoded as the time interval between an information pulse and the immediately preceding information pulse.
In order to convey information in RPPM, the time position of each pulse must fall within a predefined window of time having a duration T that is located relative to the preceding pulse. The time window of duration T is divided into M time segments, each having a duration T/M. A pulse occurring in a particular one of the time segments is considered to represent a corresponding particular piece of information. In a binary RPPM system, M=2 and the two time positions represent the binary values 0 and 1. In a 4-bit nibble RPPM system, M=16 and the 16 time positions represent the 4-bit binary values 0000 through 1111, which can also be expressed as decimal values 0 through 15.
In RPPM communication systems, errors will manifest themselves as (a) additional pulses, (b) missing pulses, or (c) time-shifted pulses. Pulses occurring outside of the predefined time window T will be classified as range errors and will be detected by reception hardware prior to error detection decoding. The responsibility of the error detection decoding is then limited to detecting those errors, primarily pulses that are time-shifted within time window T, that are not detected by the reception hardware.
In RPPM communication systems, time-shifted pulses will cause opposing adjacent errors in the data. An error which shifts the time position of a pulse one time segment T/M too late will result in the preceding interval being decoded as a value one greater than correct, and the subsequent interval will be decoded as a value one less than correct. As an example, assume a block of four sequential nibbles with values of 13, 10, 3, and 7 is transmitted. The first two nibbles are defined by three sequential pulses. If the second pulse is time-shifted to cause the first nibble to appear as 14, the second nibble will appear as 9. The remaining nibbles would not be affected by the single pulse position error. In this example, a single pulse-position error results in opposing adjacent errors in the sequential data, in that the first data value appears greater than the correct value, and the second adjacent data value appears smaller than the correct value.
Prior art standard block code does not exploit the opposing adjacent errors characteristic of RPPM for error detection. For example, assume a standard block code where the redundant information is the complement of the message information, according to the following table.
______________________________________ Original Data Complement Data Binary Decimal Binary Decimal ______________________________________ 0000 0 1111 15 0001 1 1110 14 0010 2 1101 13 0011 3 1100 12 0100 4 1011 11 0101 5 1010 10 0110 6 1001 9 0111 7 1000 8 1000 8 0111 7 1001 9 0110 6 1010 10 0101 5 1011 11 0100 4 1100 12 0011 3 1101 13 0010 2 1110 14 0001 1 1111 15 0000 0 ______________________________________
A single pulse-position error in the pulses conveying the message data will affect two message data nibbles due to the opposing adjacent errors characteristic of RPPM. A single pulse-position error in the corresponding pulses conveying the redundant data can affect two redundant data nibbles in a direction opposite to that of the first error so as to make the errors in the block undetectable. For example, a 4 nibble message may be EQU 13, 10, 3, 7,
and the resulting block code (message+complement) would be EQU 13, 10, 3, 7, 2, 5, 12, 8.
A single pulse-position error in the second pulse such that the pulse is detected one T/M interval too late would create the code EQU 14, 9, 3, 7, 2, 5, 12, 8
which would be detectable as an error since the first two message elements 14, 9 would fail a comparison with their complement redundant elements 2, 5. However, an additional error in the sixth pulse such that the pulse is detected one T/M interval too soon would create the code EQU 14, 9, 3, 7, 1, 6, 12, 8
which would be an undetectable error. The first two message elements 14, 9 would pass a comparison with their complement redundant elements 1, 6. Thus, two pulse-position errors occurring in an eight element block could result in data errors that are undetectable. The likelihood of this error combination is the same as that for a similar pulse position modulated system which does not have the opposing adjacent errors characteristic.